package com.dk.task;

public class MyThread01 extends Thread {

    public static int tick = 0;

    @Override
    public void run() {
        while (true) {
            if (tick < 100) {
                tick++;
                System.out.println(super.getName() + "卖出第" + tick + "张票");
            } else {
                break;
            }
        }
    }
}
